#!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# QcmWidgets demo Copyright (C) 2009  Chris Marsh
#
# QcmWidgets is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or any later version.
#
# This program is distributed in the hope that it will be useful, 
# but WITHOUT ANY WARRANTY; without even the implied warranty
# of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program.  If not, see <http://www.gnu.org/licenses/>.

import sys
from PyQt4.QtCore import *
from PyQt4.QtGui import *
from QcmDoubleEdit import QcmDoubleEdit,  QcmCalculatorEdit
from QcmLineEdit import QcmLineEdit

class QcmDemo(QWidget):
        
    def __init__(self, parent = None):
        super(QcmDemo, self).__init__(parent)
        
        layout = QGridLayout()
        qcmDoubleEdit = QcmDoubleEdit(4)
        qcmCalculatorEdit = QcmCalculatorEdit(4)
        qcmLineEdit = QcmLineEdit()
        layout.addWidget(QLabel("QcmDoubleEdit Value :"),  0,  0)
        layout.addWidget(qcmDoubleEdit,  0,  1)
        layout.addWidget(QLabel("QcmCalculatorEdit Value :"),  1,  0)
        layout.addWidget(qcmCalculatorEdit,  1,  1)
        layout.addWidget(QLabel("QcmLineEdit Value:"),  2,  0)
        layout.addWidget(qcmLineEdit,  2,  1)
        self.setLayout(layout)
        self.setWindowTitle("QcmWidgets Demo")

if __name__ == "__main__":
    
    app = QApplication(sys.argv)
    form = QcmDemo()
    form.show()
    sys.exit(app.exec_())
